<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改话术')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-trick-edit" th:object="${verbalTrick}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label">话术：</label>
                <div class="col-sm-8">
                    <input name="verbalTrick" th:field="*{verbalTrick}" class="form-control" type="text" >
<!--                    <select id="tri">-->

<!--                    </select>-->
<!--                    <datalist id="trick">-->
<!--                        <option value="中国 北京">-->
<!--                        <option value="中国 上海">-->
<!--                        <option value="中国 广州">-->
<!--                        <option value="中国 深圳">-->
<!--                        <option value="中国 东莞">-->
<!--                    </datalist>-->
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">设备编号：</label>
                <div class="col-sm-8">
                    <input name="equipmentId" th:field="*{equipmentId}" class="form-control" type="text">
                </div>
            </div>
<!--            <div class="form-group">    -->
<!--                <label class="col-sm-3 control-label">微信号：</label>-->
<!--                <div class="col-sm-8">-->
<!--                    <input name="wechatId" th:field="*{wechatId}" class="form-control" type="text">-->
<!--                </div>-->
<!--            </div>-->
            <div class="form-group">
                <label class="col-sm-3 control-label">登录名称：</label>
                <div class="col-sm-8">
                    <input name="userName" th:field="*{userName}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">请求次数：</label>
                <div class="col-sm-8">
                    <input name="userName" th:field="*{number}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">间隔时间：</label>
                <div class="col-sm-8">
                    <input name="userName" th:field="*{intervalTime}" class="form-control" type="text">
                </div>
            </div>
        </form>
    </div>

<!--    <select id="trick" placeholder="请选择">-->

<!--    </select>-->

<!--    <script>-->
<!--        $.post("/system/list/trick/",{},function(data){-->
<!--            var carbrand = $("#trick"); //这里是<select>标签的id-->
<!--            var opj = "";-->
<!--            for(var i=0;i<data.length;i++){-->
<!--                opj += "<option value='"+data[i].id+"'>"+data[i].verbalTrick+"</option>";-->
<!--            }-->
<!--            carbrand.append(opj);-->
<!--        });-->
<!--    </script>-->

    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/trick";
        $("#form-trick-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-trick-edit').serialize());
            }
        }


        var history = [];
        inputDom.addEventListner('verbalTrick',e=>{
            history.push(e.target.value)
        })
    </script>
</body>
</html>